/**
 *  
 * 数据
 * 
 */
class AppData extends BaseClass {
    public currentScore: number = 0;


    public static get get(): AppData {
        return super.getInstance();
    }
    
    public reset(){
        this.currentScore =0;
    }
    
    public chooseA() {
        this.currentScore += 4;
    }

    public chooseB() {
        this.currentScore += 3;
    }

    public chooseC() {
        this.currentScore += 2;
    }
    public chooseD() {
        this.currentScore += 1;
    }
    /**
     * 1、小玉；2、花轮；3、丸尾；4、小丸子；5、美环
     */
    public isWhatRole(): number {
        var role = 1;
        if(this.currentScore >= 6 && this.currentScore <= 9) {
            role = 1;
        } else if(this.currentScore >= 10 && this.currentScore <= 13) {
            role = 2;
        } else if(this.currentScore >= 14 && this.currentScore <= 17) {
            role = 3;
        } else if(this.currentScore >= 18 && this.currentScore <= 21) {
            role = 4;
        } else if(this.currentScore >= 22 && this.currentScore <= 24) {
            role = 5;
        }
        return role;
    }


}
